package com.ygqh.baby.service;

import com.ygqh.baby.ao.AppType;
import com.ygqh.baby.ao.Message;
import com.ygqh.baby.ao.QueryInfo;
import com.ygqh.baby.ao.ResultSet;
import com.ygqh.baby.model.PrizeItem;
import com.ygqh.baby.model.PrizeItem.Type;
import com.ygqh.baby.po.YgUser;
import com.ygqh.baby.po.YgUserAddress;
import com.ygqh.baby.po.YgUserPrize;

import java.math.BigDecimal;
import java.util.List;

public interface YgUserPrizeService {

	List<YgUserPrize> find();

	int findCount();

	YgUserPrize findById(Long id);

	int deleteSoft(Long[] ids);

	int deleteSoft(Long id);

	int save(YgUserPrize ygUserPrize);

	int update(YgUserPrize ygUserPrize);

	int saveOrUpdate(YgUserPrize ygUserPrize);

	ResultSet<YgUserPrize> search(QueryInfo queryInfo, String q);

	List<YgUserPrize> findPrizeItemByUserId(Long id, Type type, String sourceCode);

	int writeBackCount(PrizeItem prizeItem, Long userId, String sourceCode);

	Message cashPrize(Long priziId, BigDecimal quantity, YgUser user, YgUserAddress address);

	Message generateCardCoupon(Long userId, Long cardId, String source);

	Message cashPrize(Long skuId, String source, YgUserAddress address, String platformNo, AppType appType);
}
